import { postData } from '../data-source/commonRequestApi';

// 分页查询连带规范性动作配置
const getPageSubjectPage = (param) => postData('/subject-manage/page', param);

// 批量删除
const batchDelete = (param) => postData('/subject-manage/batch-delete', param);

// 新增/编辑
const saveSubject = (param) => postData('/subject-manage/save', param);

// 导入
const importSubject = (param) => postData('/subject-manage/import', param);

// 根据登陆人获取连带规范性动作配置
const getSubjectByLoginUser = (param) => postData('/subject-manage/subject-by-user', param);

// 连带性规范详细信息
const getSubjectDetail = (param) => postData('/subject-manage/detail', param);

// 历史工单
const getWorkList = (param) => postData('/work-arrangement/page', param);

// 连带规范性动作排序
const subjectUpdateOrder = (params) => postData('/subject-manage/update-order', params);

export {
  getPageSubjectPage,
  batchDelete,
  saveSubject,
  importSubject,
  getSubjectByLoginUser,
  getSubjectDetail,
  getWorkList,
  subjectUpdateOrder,
};
